import request from '@/axios'

function formatRequestUri(name) {
  return 'hr/DeptPower/' + name
}
export function set(empId: string, companyId: string, deptId: string[]) {
  return request.post({
    url: formatRequestUri('Set'),
    data: {
      EmpId: empId,
      CompanyId: companyId,
      DeptId: deptId
    }
  })
}
export function get(empId: string, companyId: string) {
  return request.get({
    url: formatRequestUri('Get'),
    params: {
      empId,
      companyId
    }
  })
}
